package cn.net.xyan.easy.webapp.base.dao;

import cn.net.xyan.easy.spring.jpa.utils.EasyJpaRepository;
import cn.net.xyan.easy.webapp.base.entity.WebModule;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
 * Created by xiashenpin on 16/2/9.
 */
public interface WebModuleDao extends EasyJpaRepository<WebModule,String> {
    @Query("select m from WebModule m where m.parent is null order by m.orderIndex")
    List<WebModule> rootModules();
}
